package com.paperyy.module.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.paperyy.module.bean.Consume;
import com.paperyy.module.dao.ConsumeDao;
import com.paperyy.module.service.ConsumeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ConsumeServiceImpl implements ConsumeService {
    @Autowired
    private ConsumeDao consumeDao;

    //插入语句
    public Integer insert(Consume consume) {
        int consume1 = consumeDao.insert(consume);
        return consume1;
    }

    //查询所有消费记录信息
    public List<Consume> findAll() {
        return consumeDao.selectList(new LambdaQueryWrapper<>());
    }


}
